Update Packages#1337
Conversation
| "moduleResolution": "bundler", | ||
| "allowImportingTsExtensions": true, | ||
| "isolatedModules": true, | ||
| "verbatimModuleSyntax": true, |
There was a problem hiding this comment.
It would be good to include notes (in the PR description) on the motivation to use this flag vs isoladedModules e.g. how does it specific benefit developer experience, bundle size, etc. There are some comparisons in this reference.
There was a problem hiding this comment.
Saves a little of space by not using enums. And import type helps to different real classes from typescript types/interfaces.
| "target": "ES2020", | ||
| "target": "ES2022", | ||
| "useDefineForClassFields": true, | ||
| "lib": ["ESNext", "DOM", "DOM.Iterable", "WebWorker"], |
There was a problem hiding this comment.
Why the choice to remove WebWorker here?
There was a problem hiding this comment.
I still have it.
| await OneSignal.User.addTags(finalTagsObject); | ||
| return finalTagsObject; |
There was a problem hiding this comment.
Are these two functionally the same?
return (await OneSignal.User.addTags(
finalTagsObject,
)) as TagsObjectForApi;
There was a problem hiding this comment.
AddTags doesnt return anything but the outer function (sendTags) has this Promise<TagsObjectForApi>.
798f869 to
cce1caf
Compare
cce1caf to
e78fe31
Compare
Description
1 Line Summary
Update vite packages and use recommend tsconfig settings.
Details
erasableSyntaxOnlyto discourage use of enums and other things in the appverbatimModuleSyntaxto force import type when importing interfaces e.g.Systems Affected
Validation
Tests
Info
Checklist
Programming Checklist
Interfaces:
Functions:
Typescript:
Other:
elem of arraysyntax. PreferforEachor usemapcontextif possible. Instead, we can pass it to function/constructor so that we don't callOneSignal.contextScreenshots
Info
Checklist
Related Tickets
This change is